Produced by John Yuill
All source code and data used is available in my Github repo:
proj-r-van-weather
Govt of Canada Historical Weather data
Data is collected from:
http://climate.weather.gc.ca/historical_data/search_historic_data_e.html
Data is available from the government on a daily basis and updated occasionally here. ;)
Date range currently covered:
Earliest date: 1970-01-01
Most recent date: 2021-07-04
The following weather stations are represented. Not the preferred approach but I couldn’t find continuous data for any single weather station.
Check data structure and summary:
spec_tbl_df [18,812 × 11] (S3: spec_tbl_df/tbl_df/tbl/data.frame)
$ Date : Date[1:18812], format: "1970-01-01" "1970-01-02" ...
$ Year : Factor w/ 52 levels "1970","1971",..: 1 1 1 1 1 1 1 1 1 1 ...
$ Month : Factor w/ 12 levels "1","2","3","4",..: 1 1 1 1 1 1 1 1 1 1 ...
$ Day : num [1:18812] 1 2 3 4 5 6 7 8 9 10 ...
$ Season : Factor w/ 4 levels "Winter","Spring",..: 1 1 1 1 1 1 1 1 1 1 ...
$ Season.Yr : num [1:18812] 1970 1970 1970 1970 1970 1970 1970 1970 1970 1970 ...
$ Max.Temp : num [1:18812] 6.1 2.2 5 2.8 1.7 5.6 3.3 4.4 7.2 5.6 ...
$ Min.Temp : num [1:18812] -1.7 0 -1.7 -3.3 -2.8 -1.7 -3.3 0 2.8 -2.8 ...
$ Mean.Temp : num [1:18812] 2.2 1.1 1.7 -0.3 -0.6 2 0 2.2 5 1.4 ...
$ Total.Precip: num [1:18812] 0 1 0.5 0 0 0 0 4.6 6.6 0.5 ...
$ Station : chr [1:18812] "VANCOUVER INT'L A" "VANCOUVER INT'L A" "VANCOUVER INT'L A" "VANCOUVER INT'L A" ...
- attr(*, "spec")=
.. cols(
.. Date = col_date(format = ""),
.. Year = col_double(),
.. Month = col_double(),
.. Day = col_double(),
.. Season = col_character(),
.. Season.Yr = col_double(),
.. Max.Temp = col_double(),
.. Min.Temp = col_double(),
.. Mean.Temp = col_double(),
.. Total.Precip = col_double(),
.. Station = col_character()
.. )
Date Year Month Day
Min. :1970-01-01 1972 : 366 1 :1612 Min. : 1.00
1st Qu.:1982-11-16 1976 : 366 3 :1612 1st Qu.: 8.00
Median :1995-10-03 1980 : 366 5 :1612 Median :16.00
Mean :1995-10-03 1984 : 366 7 :1585 Mean :15.72
3rd Qu.:2008-08-18 1988 : 366 8 :1581 3rd Qu.:23.00
Max. :2021-07-04 1992 : 366 10 :1581 Max. :31.00
(Other):16616 (Other):9229
Season Season.Yr Max.Temp Min.Temp
Winter:4661 Min. :1970 Min. :-8.70 Min. :-15.200
Spring:4784 1st Qu.:1982 1st Qu.: 8.90 1st Qu.: 2.800
Summer:4726 Median :1995 Median :13.30 Median : 6.800
Fall :4641 Mean :1995 Mean :13.83 Mean : 6.703
3rd Qu.:2008 3rd Qu.:19.00 3rd Qu.: 11.300
Max. :2021 Max. :34.40 Max. : 22.400
NA's :46 NA's :39
Mean.Temp Total.Precip Station
Min. :-11.50 Min. : 0.000 Length:18812
1st Qu.: 6.00 1st Qu.: 0.000 Class :character
Median : 10.00 Median : 0.000 Mode :character
Mean : 10.29 Mean : 3.214
3rd Qu.: 15.20 3rd Qu.: 3.600
Max. : 28.40 Max. :91.600
NA's :48 NA's :54